import net.sourceforge.jeval.EvaluationException;
import net.sourceforge.jeval.Evaluator;


public class EquationParser
{
	public static void main(final String... the_args)
	{
		Evaluator evaluator = new Evaluator();

		try
		{
			System.out.println(evaluator.evaluate("cos(" + Math.PI + ")"));
			
			double P = 2000;
			double T = 1000;
			
			System.out.println(evaluator.evaluate(P + "<" + T));
			System.out.println(evaluator.evaluate(P + ">" + T));
		}
		catch (EvaluationException e)
		{
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
	}
}
